Here is a useful trick when you need to debug android app with out connnecting to USB, maybe you have limited USB ports or you don’t want to see so many wires in front of you.
Required:
- WIFI environment, make sure your android device and your PC is in the same WLAN
- of course one android device, but no root is ok
Steps:
1.connect your device with USB and open debug option
2.open a terminal and use adb tcpip 5555
3.adb connect *.*.*.*:5555 //* stands for ip of your device
4.you can disconnect usb and start wireless debug now
5.use adb usb to end wireless debug.
Wish this helpful!